﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:uc="clr-namespace:FileExplorer.WPF.UserControls"
    xmlns:bc="clr-namespace:FileExplorer.WPF.BaseControls"
    xmlns:conv="clr-namespace:QuickZip.Converters"
    >
    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="pack://application:,,,/FileExplorer3.WPF;component/Themes/Common/Converters.xaml" />
        <ResourceDictionary Source="pack://application:,,,/FileExplorer3.WPF;component/Themes/Common/Buttons.xaml" />
    </ResourceDictionary.MergedDictionaries>

    <!--<ControlTemplate x:Key="ClippedBorderTemplate" TargetType="{x:Type bc:ClipCorner}">
        <Border BorderBrush="Transparent" BorderThickness="1" CornerRadius="{TemplateBinding CornerRadius}">
            <Border.Clip>
                <MultiBinding Converter="{StaticResource bc}">
                    <Binding Path="ActualWidth" RelativeSource="{RelativeSource Self}"/>
                    <Binding Path="ActualHeight" RelativeSource="{RelativeSource Self}"/>
                    <Binding Path="CornerRadius" RelativeSource="{RelativeSource Self}"/>
                </MultiBinding>
            </Border.Clip>
            <ContentPresenter />                
            
        </Border>
    </ControlTemplate>-->

    <Style TargetType="{x:Type bc:ClipCorner}">
        <Setter Property="Clip" >
            <Setter.Value>
                <MultiBinding Converter="{StaticResource bc}">
                    <Binding Path="ActualWidth" RelativeSource="{RelativeSource  TemplatedParent}"/>
                    <Binding Path="ActualHeight" RelativeSource="{RelativeSource TemplatedParent}"/>
                    <Binding Path="CornerRadius" RelativeSource="{RelativeSource TemplatedParent}"/>
                </MultiBinding>
            </Setter.Value>
            
        </Setter>
    </Style>


</ResourceDictionary>